package com.atguigu.spzx.cloud.api.fallback;

import com.atguigu.spzx.cloud.api.UserFeignClient;
import com.atguigu.spzx.cloud.entity.User;
import org.springframework.stereotype.Component;

@Component
public class UserFeignClientImpl implements UserFeignClient {
    @Override
    public User queryById(Long userId) {
        System.out.println("用户查找发生错误,进行服务降级");
        User user = new User();
        user.setUserName("服务降级USERNAME");
        return user;
    }
}
